<?php 
include TMPL_PATH.'public/header.phtml';
?>
<div class="subnav">
    <div class="content-menu ib-a blue line-x">
        <a href='javascript:;' class="on"><em>系列管理</em></a> <span>|</span> <a href="<?php echo U('collection/add')?>"><em>添加系列</em></a> </div>
       
</div>
<div class="pad_10">
<div class="table-list">
    <table>
        <tr>
            <td align="center">系列编号</td>
            <td align="center">url地址</td>
            <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;系列标题</td>
            <td align="center">编辑</td>
        </tr>        
    <?php foreach($list as $k=>$v):?>
        <tr>
            <td><?php echo $v['collection_id']?></td>
            <td>www.ownonly.com/index/<?php echo $v['url_path']?></td>
            <td>&nbsp;&nbsp;&nbsp;&nbsp;<?php echo $v['collection_title']?></td>
            <td><a href="<?php echo url('collection/edit').'&id='.$v['collection_id']?>">修改</a>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <a href="javascript:confirmurl('<?php echo url('collection/del').'&id='.$v['collection_id']?>','确认要删除吗？')">删除</a></td>
        </tr>
    <?php endforeach;?>
        </table>
</div>
</div>
</body>
<script>
    function confirmurl(url,message) {
if(confirm(message)) redirect(url);
}
function redirect(url) {
location.href = url;
} 
    </script>
</html>
